//
//  TYJsonData.h
//  Project
//
//  Created by 谢航宇_WORK on 2022/1/12.
//  Copyright © 2022 谢航宇. All rights reserved.
//

#import <Foundation/Foundation.h>

NS_ASSUME_NONNULL_BEGIN

@interface NSString (TYJsonData)
+ (NSString *)getStringFromObj:(id)obj;
///根据字典获取json字符串()
+ (NSString *)getStringFromDictionary:(NSDictionary *)dic;
+ (NSString *)getEncodeStringFromDictionary:(NSDictionary *)dic;
///根据数组获取json字符串()
+ (NSString *)getStringFromArray:(NSArray *)ary;
+ (NSString *)getEncodeStringFromArray:(NSArray *)ary;
///根据字典获取POST请求字符串()
+ (NSString *)getRequestStringFromDictionary:(NSDictionary *)dic;
@end


@interface NSDictionary (TYJsonData)
+ (NSDictionary *)getDictionaryFromObj:(id)obj;

+ (NSDictionary *)getDictionaryFromString:(NSString *)jsonString;
+ (NSDictionary *)getDictionaryFromData:(NSData *)data;

+ (NSDictionary *)getAllPropertiesKeyAndValue:(id)obj; 
@end
NS_ASSUME_NONNULL_END
